package com.rover022.flixelgame.element.weapon
{
	import com.rover022.flixelgame.element.BaseElement;

	/**
	 * 剑
	 * 直接从敌人内部发出攻击
	 * @author flashpig
	 */
	public class Sword extends BaseFlxWeapon
	{
		public function Sword(name:String, parentRef:* = null, xVariable:String = "x", yVariable:String = "y")
		{
			super(name, parentRef, xVariable, yVariable);
		}

		/**
		 * @param target
		 * @return
		 */
		override public function fireAtElement(target:BaseElement):Boolean
		{
			//直接收到伤害
			target.hurtFrom(this.parent);
			return true;
		}
	}
}
